package xin.marcher.module.construction.api;

import xin.marcher.module.common.core.JsonResult;
import xin.marcher.module.common.core.PageResult;
import xin.marcher.module.construction.domain.dto.AuditInfoDTO;
import xin.marcher.module.construction.domain.dto.DraftDetailDTO;
import xin.marcher.module.construction.domain.dto.ExecAuditDTO;
import xin.marcher.module.construction.domain.request.AuditRequest;
import xin.marcher.module.construction.domain.request.FullDraftDataRequest;
import xin.marcher.module.construction.domain.request.QueryDraftRequest;
import xin.marcher.module.construction.domain.request.QueryTodoListRequest;

/**
 * 审批服务接口
 */
public interface AuditApi {

    /**
     * 保存草稿信息
     *
     * @param request
     * @return
     */
    JsonResult<Boolean> saveDraft(FullDraftDataRequest request);

    /**
     * 获取待办列表
     *
     * @param request
     * @return
     */
    JsonResult<PageResult<AuditInfoDTO>> getTodoList(QueryTodoListRequest request);

    /**
     * 获取草稿详情
     *
     * @param request
     * @return
     */
    JsonResult<DraftDetailDTO> getDraftDetail(QueryDraftRequest request);

    /**
     * 流程审批
     *
     * @param request
     * @return
     */
    JsonResult<ExecAuditDTO> execAudit(AuditRequest request);
}
